#!/usr/bin/env python3
#-*- coding:utf-8 -*-
#*********************************************************************
# @file     ycm_cpp_compiler_config.py
# @brief    对文件的简要说明
# @details  对文件的详细说明
# @author   jcai
# @date     2023-05-05 02:20:25
# @copyright Copyright &copy; 2023 wy1107412334@163.com All rights reserved
# @version  v0.0.1
#
# \n Email:  wy1107412334@163.com
# \n Blog:   None
# \n Github: https://github.com/wy1107412334
# \n Gitee:  https://gitee.com/git.git1107412334.com
#*********************************************************************
# @note
# None.
#*********************************************************************
# @attention
# None.
#*********************************************************************
#@verbatim
#@endverbatim
#*********************************************************************
# @par 历史记录
# 1. v0.0.1: jcai, 2023-05-05 02:20:25
#   - 首次编写
#
#<center>Copyright &copy; 2023 wy1107412334@163.com All rights reserved</center>
#*********************************************************************

from distutils.sysconfig import get_python_inc

# These are the compilation flags that will be used in case there's no
# compilation database set (by default, one is not set).
# CHANGE THIS LIST OF FLAGS. YES, THIS IS THE DROID YOU HAVE BEEN LOOKING FOR.
flags = [
'-Wall',
'-Wextra',
'-Werror',
'-Wno-long-long',
'-Wno-variadic-macros',
'-fexceptions',
'-DNDEBUG',
# You 100% do NOT need -DUSE_CLANG_COMPLETER and/or -DYCM_EXPORT in your flags;
# only the YCM source code needs it.
'-DUSE_CLANG_COMPLETER',
'-DYCM_EXPORT=',
'-DYCM_ABSEIL_SUPPORTED',
# THIS IS IMPORTANT! Without the '-x' flag, Clang won't know which language to
# use when compiling headers. So it will guess. Badly. So C++ headers will be
# compiled as C headers. You don't want that so ALWAYS specify the '-x' flag.
# For a C project, you would set this to 'c' instead of 'c++'.
'-x',
'c++',
'-isystem',
'cpp/absl',
'-isystem',
'cpp/pybind11',
'-isystem',
'cpp/whereami',
'-isystem',
'cpp/BoostParts',
'-isystem',
get_python_inc(),
'-isystem',
'cpp/llvm/include',
'-isystem',
'cpp/llvm/tools/clang/include',
'-I',
'cpp/ycm',
'-I',
'cpp/ycm/ClangCompleter',
'-isystem',
'cpp/ycm/tests/gmock/googlemock/include',
'-isystem',
'cpp/ycm/tests/gmock/googletest/include',
'-isystem',
'cpp/ycm/benchmarks/benchmark/include',
'-std=c++17',

# 添加本机 g++ 编译器的头文件搜索路经
'-I', '/usr/include/c++/8',
'-I', '/usr/include/x86_64-linux-gnu/c++/8',
'-I', '/usr/include/c++/8/backward',
'-I', '/usr/lib/gcc/x86_64-linux-gnu/8/include',
'-I', '/usr/local/include',
'-I', '/usr/lib/gcc/x86_64-linux-gnu/8/include-fixed',
'-I', '/usr/include/x86_64-linux-gnu',
'-I', '/usr/include',
]


def compiler_options_get():
    return flags








#***  Copyright (C) 2023 wy1107412334@163.com All rights reserved ****
#****************************** END OF FILE **************************

